<template>
  <el-dialog :model-value="sampleDialog" title="标本查看" width="70%">
    <avue-crud :data="tableData" :option="option" :page="page"> </avue-crud>
    <template #footer>
      <div class="dialog-footer">
        <el-button @click="$emit('update:sampleDialog', false)">关闭</el-button>
      </div>
    </template>
  </el-dialog>
</template>

<script setup>
import { ref } from 'vue';
const option = reactive({
  border: true,
  stripe: true,
  index: false,
  
  addBtn: false,
  column: [
    {
      label: '标本编号',
      prop: 'specimenId',
      width: 120,
    },
    {
      label: '病人姓名',
      prop: 'patientName',
      width: 110,
    },
    {
      label: '标本类型',
      prop: 'specimenType',
      width: 110,
    },
    {
      label: '标本源分类',
      prop: 'sourceCategory',
      width: 120,
    },
    {
      label: '标本源名称',
      prop: 'sourceName',
      width: 130,
    },
    {
      label: '标本份量',
      prop: 'specimenAmount',
      width: 110,
    },
    {
      label: '状态',
      prop: 'status',
      width: 100,
    },
    {
      label: '状态', // 根据图片可能存在重复列
      prop: 'status2',
      width: 100,
      hide: true,
    },
    {
      label: '采集时间',
      prop: 'collectionTime',
      width: 130,
      type: 'datetime',
      format: 'yyyy-MM-dd HH:mm',
    },
    {
      label: '入库信息',
      prop: 'storageInfo',
      width: 120,
    },
    {
      label: '出库信息',
      prop: 'outboundInfo',
      width: 120,
    },
    
  ],
});

// 分页配置
const page = reactive({
  total: 0,
  pageSize: 10,
  background: true,
});
// 空数据
const tableData = ref([]);
defineProps({
  sampleDialog: {
    type: Boolean,
    default: false,
  },
});
</script>
